import { observable, action, autorun, toJS } from 'mobx';
import * as  Apis from '../../../apis/project';
import { message } from 'antd';
import { WeaLocaleProvider } from "ecCom"
const getLabel = WeaLocaleProvider.getLabel;

export class PrjStasticStore {

    @observable prjid = "";
    @observable stastics = [];  //统计报告
    @observable loading = false;
    
    initDatas = (prjid) => {
        this.prjid = prjid;
        this.getPrjStastics();
    }

    	//统计报告
	getPrjStastics = (params = {}) => {
		this.loading = true;
		Apis.getPrjStastics({ prjid: this.prjid, ...params }).then(data => {
			this.stastics = data;
			this.loading = false;
		})
	}
}